<!-- $Id: account_list.htm 14928 2008-10-06 09:25:48Z testyang $ -->
{if $full_page}
{include file="pageheader.htm"}

{insert_scripts files="../js/utils.js,listtable.js"}

<!--
<div class="form-div">
<form method="post" action="account_log.php?act=list&user_id={$smarty.get.user_id}" name="searchForm">
  <select name="account_type" onchange="document.forms['searchForm'].submit()">
    <option value="" {if $account_type eq ''}selected="selected"{/if}>{$lang.all_account}</option>
    <option value="user_money" {if $account_type eq 'user_money'}selected="selected"{/if}>{$lang.user_money}</option>
    <option value="frozen_money" {if $account_type eq 'frozen_money'}selected="selected"{/if}>{$lang.frozen_money}</option>
    <option value="rank_points" {if $account_type eq 'rank_points'}selected="selected"{/if}>{$lang.rank_points}</option>
    <option value="pay_points" {if $account_type eq 'pay_points'}selected="selected"{/if}>{$lang.pay_points}</option>
  </select>
  <strong>{$lang.label_user_name}</strong>{$user.user_name}
  <strong>{$lang.label_user_money}</strong>{$user.formated_user_money}
  <strong>{$lang.label_frozen_money}</strong>{$user.formated_frozen_money}
  <strong>{$lang.label_rank_points}</strong>{$user.rank_points}
  <strong>{$lang.label_pay_points}</strong>{$user.pay_points}
  </form>
</div>
--><div class="tab-div">
	<div class="form-div">
	  <form action="drp.php?act=order_list&is_separate={$is_separate}" method="post" name="searchForm"> 
		<img src="images/icon_search.gif" width="26" height="22" border="0" alt="SEARCH" />  
		&nbsp;订单号&nbsp;
		<input type="text" name="order_sn" size="14" />&nbsp;&nbsp;
		<input type="submit" value="{$lang.button_search}" />
	  </form>
	</div>
    <!-- tab bar -->
    <div id="tabbar-div">
        <p>
            <a href="drp.php?act=order_list&is_separate=0"><span class="{if $is_separate eq 0}tab-front{else}tab-back{/if}" id="basic-tab">未分成订单</span></a>
            <a href="drp.php?act=order_list&is_separate=1"><span class="{if $is_separate eq 1}tab-front{else}tab-back{/if}" id="shop_info-tab">已分成订单</span></a>
        </p>
    </div>
<form method="post" action="" name="listForm">
    <div class="list-div" id="listDiv">
        {/if}
        <!--用户列表部分-->
        <table cellpadding="3" cellspacing="1">
            <tr>
                <th>{$lang.order_id}</th>
                <th>订单金额</th>
                <th>{$lang.order_stats.name}</th>
                <th>佣金明细</th>
                <th>{$lang.user_name}</th>
                <th>{$lang.parent_name}</th>
                {if $is_separate eq 0}<th>{$lang.handler}</th>{/if}

            <tr>
                {foreach from=$list item=li}
            <tr>
                <td>{$li.order_sn}</td>
                <td>{$li.goods_amount}</td>
                <td>{$lang.os[$li.order_status]},{$lang.ps[$li.pay_status]},{$lang.ss[$li.shipping_status]}</td>
                <td>{foreach from=$li.log item=l}
                    用户：{$l.name};明细:{$l.change_desc}<br>
                    {/foreach}</td>
                <td>{$li.user_name}</td>
                <td>{$li.parent_name}</td>
                {if $is_separate eq 0}
                <td align="center">
                    {if $li.separate eq 1}
                        <a href="javascript:confirm_redirect(separate_confirm, 'drp.php?act=separate&oid={$li.order_id}')">{$lang.affiliate_separate}</a>
                    {else}
                        <span style="color:#e3e3e3;">{$lang.affiliate_separate}</span>
                    {/if}

                </td>
                {/if}

            </tr>
            {foreachelse}
            <tr><td class="no-records" colspan="10">{$lang.no_records}</td></tr>
            {/foreach}
        </table>
        <table id="page-table" cellspacing="0">
            <tr>
                <td align="right" nowrap="true">
                    {include file="page.htm"}
                </td>
            </tr>
        </table>

        {if $full_page}
    </div>
</form>
    </div>

<script type="text/javascript" language="javascript">
    <!--
    listTable.query = "order_list_query";
    listTable.recordCount = {$record_count};
    listTable.pageCount = {$page_count};

    {foreach from=$filter item=item key=key}
    listTable.filter.{$key} = '{$item}';
    {/foreach}

    {literal}
    onload = function()
    {
        // 开始检查订单
        startCheckOrder();
    }
    {/literal}
    //-->
</script>
{include file="pagefooter.htm"}
{/if}